Animating property values

In Kanzi you can animate object movement or object property values. Property value animation changes the value of a property from its current to a new value. Movement animation moves an object from its current to a new position. See Animating movement.

Creating a property value animation

To create a property value animation:

  1. In the Project select or create the object the property values of which you want to animate.
    For example, create a Sphere.
  2. In the Library select Animations > Timeline Sequences > Timeline Sequence > Timeline Entry where you want to create the animation, and in the Properties set the Animated Object property to the object you want this animation to animate.

    For example, use Relative paths and enter ./Sphere.

    If you are using absolute paths in the timeline entries, in the Library select the timeline sequence and in the Properties set the Reference for Absolute Paths property. This property defines the reference for the absolute paths of animation targets in the timeline entries.
    If you do not have Timeline Sequence or Timeline Entry objects, create them.
    ClosedCreating Timeline Sequences and Timeline Entries...
    1. In the Library right-click Animations > Timeline Sequences and select Create Timeline Sequence.
    2. In the Library right-click the timeline sequence where you want to create a timeline entry and select Create > Timeline Entry.
    3. Select the timeline entry and in the Properties set the Animated Object property to the element you want this animation to animate.
      For example, use Relative paths and enter ./Sphere.

      If you are using absolute paths in the timeline entries, in the Library select the timeline sequence and in the Properties set the Reference for Absolute Paths property. This property defines the reference for the absolute paths of animation targets in the timeline entries.

    For efficient management of your animations, set each timeline entry to target only one object (or hierarchy with hierarchical animations using clips and child clips).
  3. In the Project select the scene that contains the object you are animating, and in the Properties set the Background Sequence property to the timeline sequence where you want to create the animation.

  4. In the Library double-click Animations > Timeline Sequences > Timeline Sequence > Timeline Entry > Animation Clip.
    Animation Clip Editor opens.

    If you do not have an Animation Clip, create it.
    ClosedCreating animation clips...
    1. In the Library right-click the Timeline Entry and select Create > Animation Clip.
    2. In the Library select the Timeline Entry and in the Properties set the Target Animation property to the animation clip you just created.

    3. In the Library double-click the Animation Clip to open it in the Animation Clip Editor.

  5. In the Animation Clip Editor enter in the Current Time the time at which you want your animation to start.
    For example, enter 0 to start the animation when your Kanzi application starts. See Editing animation clips.
  6. In the Project select the object the property values of which you want to animate, and from the Properties drag the property you want to animate to the Animation Clip Editor.

    Kanzi Studio creates Animation Data for the property, and adds a keyframe for that property value at the value you selected as the Current Time.

    For example, click Add Properties, add Ambient Color property, and drag it to the Animation Clip Editor to animate the value of the object's ambient color.

  7. In the Properties change the value of the property you are animating.
    For example, change the Ambient Color property to red. See Editing content.

  8. In the Animation Clip Editor enter in the Current Time the time at which you want the change you made to the property to take place, and again drag from the Properties the property you are animating.

    Kanzi Studio adds the new property values to the Animation Data.

    Repeat this step as many times as you want to add keyframes to your animation.
  9. Click Play in the Kanzi Studio timeline to play the animation. See Controlling your application in the Preview.

Changing the interpolation mode between keyframes

You can change the transition mode between keyframes in your animations by using different interpolation types. In Kanzi you can use linear, step, and Bezier interpolation types.

To change the interpolation mode between keyframes:

  1. Double-click an animation clip to open it in the Animation Clip Editor.
  2. In the Animation Clip Editor use the move tool to select two or more keyframes and then select the interpolation mode:

See also

Creating a simple animation

Animating movement

Changing the interpolation mode between keyframes

Animating an object for the duration of its lifetime

Editing animation clips

Editing timeline sequences

Animations best practices

Animations